package cn.tedu.kcircle.detail.adapter.converter;

import cn.tedu.kcircle.detail.protocol.dto.DetailAddDTO;
import cn.tedu.kcircle.detail.repository.model.DetailAddModel;
import org.springframework.beans.BeanUtils;
import org.springframework.stereotype.Component;

@Component
public class DetailConverter {
    public DetailAddModel dto2Model(DetailAddDTO detailAddDTO){
        DetailAddModel detailAddModel = new DetailAddModel();
        BeanUtils.copyProperties(detailAddDTO,detailAddModel);
        return detailAddModel;
    }
}
